import request from '../utils/request.js'


//添加收藏
export const favoriteAddService = (articleid) => {
    
    const params = new URLSearchParams()
    params.append('id', articleid)
    return request.post('/favorite/add',params)
    
}
// 返回用户收藏列表
export const favoriteListService = () => {
    
    return request.get('/favorite/list')
  
}
//删除收藏
export const favoriteDeleteService = (articleid) => {

    return request.delete('/favorite/delete?id='+articleid)
  
}